public class Exer03 {
    public static void main(String[] args) {
        int[] arr={2,6,4,1};
        int[] arr2={1,2,34,3,4,5,7,23,12};
        System.out.println(successiveOdd(arr));
        System.out.println(successiveOdd(arr2));
    }

    private static boolean successiveOdd(int[] arr) {
        for (int i = 0; i < arr.length-2; i++) {
            if(arr[i]%2!=0&&arr[i+1]%2!=0&&arr[i+2]%2!=0){
                return true;
            }
        }
        return false;
    }

}
